package com.smartcommunity.controller.people;

import com.smartcommunity.bean.model.Result;
import com.smartcommunity.entity.people.BodyTemperatureSearch;
import com.smartcommunity.service.people.BodyTemperatureService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Slf4j
@RestController
@RequestMapping(value = "/temperature")
@Api(value = "小区服务-体温监测", tags = "体温监测记录")
public class BodyTemperatureController {

    @Autowired
    private BodyTemperatureService bodyTemperatureService;

    @PostMapping(value = "/searchTemperatureList")
    @ApiOperation(value = "查询体温监测记录")
    public Result getList(@RequestBody BodyTemperatureSearch search) {
        log.info("接口：searchTemperatureList：体温监测列表。");
        return bodyTemperatureService.getTemperatureList(search);
    }
}
